<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        let p1 = new Promise(function(reslove){
            console.log('执行成功');
            reslove();
        });
        let p2 = p1.then((res2)=>{
         return new Promise(function(reslove){
             console.log('执行p1里的p2');
             reslove()
         })
        });
        p1.then((res)=>{
            console.log(res);
        }).then((res2)=>{
            console.log(res2);
        })


    </script>
    
</body>
</html>